package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.BusModelAccessoriesMapper;
import com.ruoyi.system.domain.BusModelAccessories;
import com.ruoyi.system.service.IBusModelAccessoriesService;

/**
 * 领料列表Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-03-25
 */
@Service
public class BusModelAccessoriesServiceImpl implements IBusModelAccessoriesService 
{
    @Autowired
    private BusModelAccessoriesMapper busModelAccessoriesMapper;

    /**
     * 查询领料列表
     * 
     * @param id 领料列表主键
     * @return 领料列表
     */
    @Override
    public BusModelAccessories selectBusModelAccessoriesById(Long id)
    {
        return busModelAccessoriesMapper.selectBusModelAccessoriesById(id);
    }

    /**
     * 查询领料列表列表
     * 
     * @param busModelAccessories 领料列表
     * @return 领料列表
     */
    @Override
    public List<BusModelAccessories> selectBusModelAccessoriesList(BusModelAccessories busModelAccessories)
    {
        return busModelAccessoriesMapper.selectBusModelAccessoriesList(busModelAccessories);
    }

    /**
     * 新增领料列表
     * 
     * @param busModelAccessories 领料列表
     * @return 结果
     */
    @Override
    public int insertBusModelAccessories(BusModelAccessories busModelAccessories)
    {
        return busModelAccessoriesMapper.insertBusModelAccessories(busModelAccessories);
    }

    /**
     * 修改领料列表
     * 
     * @param busModelAccessories 领料列表
     * @return 结果
     */
    @Override
    public int updateBusModelAccessories(BusModelAccessories busModelAccessories)
    {
        return busModelAccessoriesMapper.updateBusModelAccessories(busModelAccessories);
    }

    /**
     * 批量删除领料列表
     * 
     * @param ids 需要删除的领料列表主键
     * @return 结果
     */
    @Override
    public int deleteBusModelAccessoriesByIds(Long[] ids)
    {
        return busModelAccessoriesMapper.deleteBusModelAccessoriesByIds(ids);
    }

    /**
     * 删除领料列表信息
     * 
     * @param id 领料列表主键
     * @return 结果
     */
    @Override
    public int deleteBusModelAccessoriesById(Long id)
    {
        return busModelAccessoriesMapper.deleteBusModelAccessoriesById(id);
    }

    @Override
    public List<String> getCountPartsCode() {
        return busModelAccessoriesMapper.getCountPartsCode();
    }

    @Override
    public List<String> getBusModelByPartsCode(String partsCode) {
        return busModelAccessoriesMapper.getBusModelByPartsCode(partsCode);
    }

    @Override
    public List<BusModelAccessories> selectBusModelAccessoriesByPartCode(String partCode) {
        return busModelAccessoriesMapper.selectBusModelAccessoriesByPartCode(partCode);
    }
}
